/*
 * @Author: szx
 * @Date: 2022-02-24 12:27:39
 * @LastEditTime: 2022-02-24 12:33:49
 * @Description:
 * @FilePath: \leetcode\1900-1999\1910\1910.js
 */
/**
 * @param {string} s
 * @param {string} part
 * @return {string}
 */
var removeOccurrences = function (s, part) {
    while (true) {
        const i = s.indexOf(part);
        if (i == -1) return s;
        s = s.slice(0, i) + s.slice(i + part.length);
    }
};
